function [] = TestPolicies(learning_algorithm_, fixed_strategy_, opponent_, indices_, keyword_, learning_episodes, test_episodes)

global system_mode;
global opponent;
global fixed_strategy;
global learning_algorithm;
global keyword;
global policy_file;

% common variables for learning and following
% opponent = opponent_;
% fixed_strategy = fixed_strategy_;
% keyword = keyword_;

% first perform the learning
% system_mode = 'learn';
% learning_algorithm = learning_algorithm_;
% 'calling start'
% start(0, learning_episodes);

system_mode = 'learn';
opponent = opponent_;
fixed_strategy = @DefaultStrategy;
learning_algorithm = @Sarsa;
keyword = 'D';
start(0,10);
% now test the generated policies
system_mode = 'follow';
for i = 1:numel(indices_)
    index = indices(i);
    policy_file = strcat('policy_',num2str(index),'_',keyword);
    start(0,test_episodes);
end

end